package com.gzx.qc.xxljob;

import com.gzx.qc.modular.voice.text.service.GzxHtVoiceTextJobService;
import com.xxl.job.core.handler.annotation.XxlJob;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;
import vip.xiaonuo.common.tenant.TenantContext;

@Slf4j
@Component
@RequiredArgsConstructor
public class AIScannerXxlJob {

    private final GzxHtVoiceTextJobService gzxHtVoiceTextJobService;

    @XxlJob("AIScannerXxlJob")
    public void aiScannerXxlJob() {
        log.info("开始定时任务------>使用AI来判定是否违规");
        TenantContext.ignoreHandle(gzxHtVoiceTextJobService::aiScanner);
    }

}
